﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Venta_Automatica.Models.ListarUsuarioModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Registrar Usuario
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Registrar Usuario</h2>

    <% using (Html.BeginForm()) {%>
        <%: Html.ValidationSummary(true) %>

        <fieldset>
            <legend>Datos del Usuario</legend>
            
            <div class="editor-label">
                <%: Html.LabelFor(model => model.dni) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.dni) %>
                <%: Html.ValidationMessageFor(model => model.dni) %>
            </div>
            
            <div class="editor-label">
                <%: Html.LabelFor(model => model.nombre) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.nombre) %>
                <%: Html.ValidationMessageFor(model => model.nombre) %>
            </div>
            
            <div class="editor-label">
                <%: Html.LabelFor(model => model.email) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.email) %>
                <%: Html.ValidationMessageFor(model => model.email) %>
            </div>
            
            <div class="editor-label">
                <%: Html.LabelFor(model => model.password) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.password) %>
                <%: Html.ValidationMessageFor(model => model.password) %>
            </div>
            
            <div class="editor-label">
                <%: Html.LabelFor(model => model.mensaje) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.mensaje) %>
                <%: Html.ValidationMessageFor(model => model.mensaje) %>
            </div>

            <div class="editor-label">
                <%: Html.LabelFor(model => model.idRol) %>
            </div>
            <div class="editor-field">
                <%: Html.TextBoxFor(model => model.idRol)%>
                <%: Html.ValidationMessageFor(model => model.idRol)%>
            </div>
            
            <h2><%: ViewData["Message"] %></h2>

            <p>
                <input type="submit" value="Crear Usuario" />
            </p>
        </fieldset>

    <% } %>

    <div>
        <%: Html.ActionLink("Retornar al Listador de Usuarios", "ListarUsuarios", "Account")%>
    </div>

</asp:Content>

